package com.mycompany.myapp.service.dto;

import java.io.Serializable;
import java.util.HashSet;
import java.util.Objects;
import java.util.Set;
import javax.validation.constraints.*;

/**
 * A DTO for the {@link com.mycompany.myapp.domain.Teacher} entity.
 */
public class TeacherDTO implements Serializable {

    private Long id;

    @NotNull
    private String teacherAccount;

    private String teacherName;

    private Integer teacherStatus;

    @NotNull
    private String teacherPassword;

    private Set<UserClassDTO> userClasses = new HashSet<>();

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getTeacherAccount() {
        return teacherAccount;
    }

    public void setTeacherAccount(String teacherAccount) {
        this.teacherAccount = teacherAccount;
    }

    public String getTeacherName() {
        return teacherName;
    }

    public void setTeacherName(String teacherName) {
        this.teacherName = teacherName;
    }

    public Integer getTeacherStatus() {
        return teacherStatus;
    }

    public void setTeacherStatus(Integer teacherStatus) {
        this.teacherStatus = teacherStatus;
    }

    public String getTeacherPassword() {
        return teacherPassword;
    }

    public void setTeacherPassword(String teacherPassword) {
        this.teacherPassword = teacherPassword;
    }

    public Set<UserClassDTO> getUserClasses() {
        return userClasses;
    }

    public void setUserClasses(Set<UserClassDTO> userClasses) {
        this.userClasses = userClasses;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (!(o instanceof TeacherDTO)) {
            return false;
        }

        TeacherDTO teacherDTO = (TeacherDTO) o;
        if (this.id == null) {
            return false;
        }
        return Objects.equals(this.id, teacherDTO.id);
    }

    @Override
    public int hashCode() {
        return Objects.hash(this.id);
    }

    // prettier-ignore
    @Override
    public String toString() {
        return "TeacherDTO{" +
            "id=" + getId() +
            ", teacherAccount='" + getTeacherAccount() + "'" +
            ", teacherName='" + getTeacherName() + "'" +
            ", teacherStatus=" + getTeacherStatus() +
            ", teacherPassword='" + getTeacherPassword() + "'" +
            ", userClasses=" + getUserClasses() +
            "}";
    }
}
